| Conditions | 1 | 
| Paths | 1 | 
| Total Lines | 147 | 
| Code Lines | 104 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Changes | 0 | ||
Small methods make your code easier to understand, in particular if combined with a good name. Besides, if your method is small, finding a good name is usually much easier.
For example, if you find yourself adding comments to a method's body, this is usually a good sign to extract the commented part to a new method, and use the comment as a starting point when coming up with a good name for this new method.
Commonly applied refactorings include:
If many parameters/temporary variables are present:
| 1 | module.exports = function () { | 
            ||
| 2 |   return { | 
            ||
| 3 | // Variables are NODE_ID and NODE_NAME (only a-z0-9\- other chars are replaced with _)  | 
            ||
| 4 | 'nodeInfos': [  | 
            ||
| 5 |       { | 
            ||
| 6 | 'name': 'Clientstatistik',  | 
            ||
| 7 |         'href': 'https://regensburg.freifunk.net/netz/statistik/node/{NODE_ID}/', | 
            ||
| 8 |         'image': 'https://grafana.regensburg.freifunk.net/render/d-solo/000000026/node?panelId=1&var-node={NODE_ID}&from=now-1d&width=650&height=350&theme=light&_t={TIME}', | 
            ||
| 9 |         'title': 'Clientstatistik für {NODE_ID} - weiteren Statistiken' | 
            ||
| 10 | },  | 
            ||
| 11 |       { | 
            ||
| 12 | 'name': 'Trafficstatistik',  | 
            ||
| 13 |         'href': 'https://regensburg.freifunk.net/netz/statistik/node/{NODE_ID}/', | 
            ||
| 14 |         'image': 'https://grafana.regensburg.freifunk.net/render/d-solo/000000026/node?panelId=2&from=now-1d&var-node={NODE_ID}&width=650&height=350&theme=light&_t={TIME}', | 
            ||
| 15 |         'title': 'Trafficstatistik für {NODE_ID} - weiteren Statistiken' | 
            ||
| 16 | },  | 
            ||
| 17 |       { | 
            ||
| 18 | 'name': 'Systemlast',  | 
            ||
| 19 |         'href': 'https://regensburg.freifunk.net/netz/statistik/node/{NODE_ID}/', | 
            ||
| 20 |         'image': 'https://grafana.regensburg.freifunk.net/render/d-solo/000000026/node?panelId=4&from=now-1d&var-node={NODE_ID}&width=650&height=350&theme=light&_t={TIME}', | 
            ||
| 21 |         'title': 'Systemlast für {NODE_ID} - weiteren Statistiken' | 
            ||
| 22 | },  | 
            ||
| 23 |       { | 
            ||
| 24 | 'name': 'Airtime',  | 
            ||
| 25 |         'href': 'https://regensburg.freifunk.net/netz/statistik/node/{NODE_ID}/', | 
            ||
| 26 |         'image': 'https://grafana.regensburg.freifunk.net/render/d-solo/000000026/node?panelId=5&from=now-1d&var-node={NODE_ID}&width=650&height=350&theme=light&_t={TIME}', | 
            ||
| 27 |         'title': 'Airtime für {NODE_ID} - weiteren Statistiken' | 
            ||
| 28 | }  | 
            ||
| 29 | ],  | 
            ||
| 30 | 'linkInfos': [  | 
            ||
| 31 |       { | 
            ||
| 32 | 'name': 'Statistik für alle Links zwischen diese Knoten',  | 
            ||
| 33 |         'image': 'https://grafana.regensburg.freifunk.net/render/d-solo/nvSNqoHmz/link?panelId=7&var-node={SOURCE_ID}&var-nodetolink={TARGET_ID}&from=now-1d&&width=650&height=350&theme=light&_t={TIME}', | 
            ||
| 34 | 'title': 'Linkstatistik des letzten Tages, min und max aller Links zwischen diesen Knoten'  | 
            ||
| 35 | }  | 
            ||
| 36 | ],  | 
            ||
| 37 | 'globalInfos': [  | 
            ||
| 38 |       { | 
            ||
| 39 | 'name': 'Globale Statistik',  | 
            ||
| 40 | 'href': 'https://regensburg.freifunk.net/netz/statistik',  | 
            ||
| 41 |         'image': 'https://grafana.regensburg.freifunk.net/render/d-solo/000000028/globals?panelId=2&from=now-7d&&width=650&height=350&theme=light&_t={TIME}', | 
            ||
| 42 | 'title': 'Globale Statistik - weiteren Statistiken'  | 
            ||
| 43 | }  | 
            ||
| 44 | ],  | 
            ||
| 45 | // Array of data provider are supported  | 
            ||
| 46 | 'dataPath': [  | 
            ||
| 47 | 'https://regensburg.freifunk.net/data/'  | 
            ||
| 48 | ],  | 
            ||
| 49 | 'siteName': 'Freifunk Regensburg',  | 
            ||
| 50 | 'mapLayers': [  | 
            ||
| 51 |       { | 
            ||
| 52 | 'name': 'Freifunk Regensburg',  | 
            ||
| 53 | // Please ask Freifunk Regensburg before using its tile server c- example with retina tiles  | 
            ||
| 54 |         'url': 'https://{s}.tiles.ffrgb.net/{z}/{x}/{y}{retina}.png', | 
            ||
| 55 |         'config': { | 
            ||
| 56 | 'maxZoom': 20,  | 
            ||
| 57 | 'subdomains': '1234',  | 
            ||
| 58 | 'attribution': '<a href="http://www.openmaptiles.org/" target="_blank">© OpenMapTiles</a> <a href="http://www.openstreetmap.org/about/" target="_blank">© OpenStreetMap contributors</a>',  | 
            ||
| 59 | 'start': 6  | 
            ||
| 60 | }  | 
            ||
| 61 | },  | 
            ||
| 62 |       { | 
            ||
| 63 | 'name': 'Freifunk Regensburg Night',  | 
            ||
| 64 | // Please ask Freifunk Regensburg before using its tile server - example with retina and dark tiles  | 
            ||
| 65 |         'url': 'https://{s}.tiles.ffrgb.net/n/{z}/{x}/{y}{retina}.png', | 
            ||
| 66 |         'config': { | 
            ||
| 67 | 'maxZoom': 20,  | 
            ||
| 68 | 'subdomains': '1234',  | 
            ||
| 69 | 'attribution': ' <a href="http://www.openmaptiles.org/" target="_blank">© OpenMapTiles</a> <a href="http://www.openstreetmap.org/about/" target="_blank">© OpenStreetMap contributors</a>',  | 
            ||
| 70 | 'mode': 'night',  | 
            ||
| 71 | 'start': 19,  | 
            ||
| 72 | 'end': 7  | 
            ||
| 73 | }  | 
            ||
| 74 | },  | 
            ||
| 75 |       { | 
            ||
| 76 | 'name': 'OpenStreetMap.HOT',  | 
            ||
| 77 |         'url': 'https://{s}.tile.openstreetmap.fr/hot/{z}/{x}/{y}.png', | 
            ||
| 78 |         'config': { | 
            ||
| 79 | 'maxZoom': 19,  | 
            ||
| 80 | 'attribution': '© Openstreetmap France | © <a href="http://www.openstreetmap.org/copyright">OpenStreetMap</a>'  | 
            ||
| 81 | }  | 
            ||
| 82 | },  | 
            ||
| 83 |       { | 
            ||
| 84 | 'name': 'HERE',  | 
            ||
| 85 | // Please use your own API key - Free plan is on right side after the pay plans  | 
            ||
| 86 |         'url': 'https://{s}.base.maps.api.here.com/maptile/2.1/maptile/newest/normal.day/{z}/{x}/{y}/256/png8?app_id=YOUR_KEY&app_code=YOUR_CODE&lg=deu', | 
            ||
| 87 |         'config': { | 
            ||
| 88 | 'attribution': 'Map © 1987-2014 <a href="http://developer.here.com">HERE</a>',  | 
            ||
| 89 | 'subdomains': '1234',  | 
            ||
| 90 | 'maxZoom': 20  | 
            ||
| 91 | }  | 
            ||
| 92 | },  | 
            ||
| 93 |       { | 
            ||
| 94 | 'name': 'Esri.WorldImagery',  | 
            ||
| 95 |         'url': '//server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}', | 
            ||
| 96 |         'config': { | 
            ||
| 97 | 'maxZoom': 20,  | 
            ||
| 98 | 'attribution': 'Tiles © Esri — Source: Esri, i-cubed, USDA, USGS, AEX, GeoEye, Getmapping, Aerogrid, IGN, IGP, UPR-EGP, and the GIS User Community'  | 
            ||
| 99 | }  | 
            ||
| 100 | },  | 
            ||
| 101 |       { | 
            ||
| 102 | 'name': 'HERE.hybridDay',  | 
            ||
| 103 | // Please use your own API key - Free plan is on right side after the pay plans  | 
            ||
| 104 |         'url': 'https://{s}.aerial.maps.api.here.com/maptile/2.1/maptile/newest/{variant}/{z}/{x}/{y}/256/png8?app_id=YOUR_KEY&app_code=YOUR_CODE&lg=deu', | 
            ||
| 105 |         'config': { | 
            ||
| 106 | 'attribution': 'Map © 1987-2014 <a href="http://developer.here.com">HERE</a>',  | 
            ||
| 107 | 'subdomains': '1234',  | 
            ||
| 108 | 'variant': 'hybrid.day',  | 
            ||
| 109 | 'maxZoom': 20  | 
            ||
| 110 | }  | 
            ||
| 111 | }  | 
            ||
| 112 | ],  | 
            ||
| 113 | // Set a visible frame  | 
            ||
| 114 | 'fixedCenter': [  | 
            ||
| 115 | // Northwest  | 
            ||
| 116 | [  | 
            ||
| 117 | 49.3522,  | 
            ||
| 118 | 11.7752  | 
            ||
| 119 | ],  | 
            ||
| 120 | // Southeast  | 
            ||
| 121 | [  | 
            ||
| 122 | 48.7480,  | 
            ||
| 123 | 12.8917  | 
            ||
| 124 | ]  | 
            ||
| 125 | ],  | 
            ||
| 126 | 'domainNames': [  | 
            ||
| 127 |       { | 
            ||
| 128 | 'domain': 'ffrgb-bat15',  | 
            ||
| 129 | 'name': 'Regensburg'  | 
            ||
| 130 | },  | 
            ||
| 131 |       { | 
            ||
| 132 | 'domain': 'ffrgb',  | 
            ||
| 133 | 'name': 'Regensburg'  | 
            ||
| 134 | }  | 
            ||
| 135 | ],  | 
            ||
| 136 | 'linkList': [  | 
            ||
| 137 |       { | 
            ||
| 138 | 'title': 'Impressum',  | 
            ||
| 139 | 'href': '/verein/impressum/'  | 
            ||
| 140 | },  | 
            ||
| 141 |       { | 
            ||
| 142 | 'title': 'Datenschutz',  | 
            ||
| 143 | 'href': '/verein/datenschutz/'  | 
            ||
| 144 | }  | 
            ||
| 145 | ]  | 
            ||
| 146 | };  | 
            ||
| 147 | };  | 
            ||
| 148 |